package com.ruoyi.lease.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.lease.mapper.TbAppointmentMapper;
import com.ruoyi.lease.domain.TbAppointment;
import com.ruoyi.lease.service.ITbAppointmentService;

/**
 * 预约管理Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-10-15
 */
@Service
public class TbAppointmentServiceImpl implements ITbAppointmentService 
{
    @Autowired
    private TbAppointmentMapper tbAppointmentMapper;

    /**
     * 查询预约管理
     * 
     * @param appointmentId 预约管理主键
     * @return 预约管理
     */
    @Override
    public TbAppointment selectTbAppointmentByAppointmentId(Long appointmentId)
    {
        return tbAppointmentMapper.selectTbAppointmentByAppointmentId(appointmentId);
    }

    /**
     * 查询预约管理列表
     * 
     * @param tbAppointment 预约管理
     * @return 预约管理
     */
    @Override
    public List<TbAppointment> selectTbAppointmentList(TbAppointment tbAppointment)
    {
        return tbAppointmentMapper.selectTbAppointmentList(tbAppointment);
    }

    /**
     * 新增预约管理
     * 
     * @param tbAppointment 预约管理
     * @return 结果
     */
    @Override
    public int insertTbAppointment(TbAppointment tbAppointment)
    {
        return tbAppointmentMapper.insertTbAppointment(tbAppointment);
    }

    /**
     * 修改预约管理
     * 
     * @param tbAppointment 预约管理
     * @return 结果
     */
    @Override
    public int updateTbAppointment(TbAppointment tbAppointment)
    {
        return tbAppointmentMapper.updateTbAppointment(tbAppointment);
    }

    /**
     * 批量删除预约管理
     * 
     * @param appointmentIds 需要删除的预约管理主键
     * @return 结果
     */
    @Override
    public int deleteTbAppointmentByAppointmentIds(Long[] appointmentIds)
    {
        return tbAppointmentMapper.deleteTbAppointmentByAppointmentIds(appointmentIds);
    }

    /**
     * 删除预约管理信息
     * 
     * @param appointmentId 预约管理主键
     * @return 结果
     */
    @Override
    public int deleteTbAppointmentByAppointmentId(Long appointmentId)
    {
        return tbAppointmentMapper.deleteTbAppointmentByAppointmentId(appointmentId);
    }
}
